﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Common;
using System.Net.Sockets;

namespace ServerYuGi
{
    public partial class SSupervisor
    {
        private bool CheckYMSG(YMSG message)
        {
            if (Turn.MessageNgoaiLe.YMSGGame.Contains(message))
                return true;
            ITurn tmp = TurnManager.GetITurnNow();
            if (!tmp.CheckYMSG(message))
            {
                Console.WriteLine("YMSG khong duoc phep gui len trong turn nay");
                //client.Disconnect(true);
                //ServerSocket.SocketClients.Remove(client);
                //ServerSocket.SendMessageToEveryOne(YMSG.GAME_END);
                return false;
            }
            return true;
        }
    }
}
